package davidlauzon.activerecord.nodes;

import davidlauzon.activerecord.visitor.SqlSerializer;

public class DeleteStatement extends SqlStatement
{
    /*********************************************************************************************
     * VARIABLES
     *********************************************************************************************/
    private Table       _from;
    private WhereClause _where;
    
    
    /*********************************************************************************************
     * SIMPLE GETTER & SETTERS
     *********************************************************************************************/
    public Table       getFrom()        { return _from; }
    public WhereClause getWhereClause() { return _where; }
    
    
    /*********************************************************************************************
     * PUBLIC METHODS
     *********************************************************************************************/
    public DeleteStatement() {
        super();
    }
    
    public void setFrom(Table from) {
        _from = from;
    }
    
    public void setWhereClause(WhereClause where) {
        _where = where;
    }

    @Override
    public String accept(SqlSerializer visitor) {
        return visitor.visit( this );
    }
}
